function login(){
    let account = $('[name=account]').val()
    let password = $('[name=password]').val()

    let obj={
        account,
        password
    }
    console.log(obj);
    $.post('http://127.0.0.1:8000/login',obj,(data)=>{
        if (data.code==200) {
            window.location.href="./index.html"
        }else{
            confirm('账号或密码错误')
        }
    })
}
